<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use DateTimeInterface;

class Cms_Member_Coud extends Model
{
    use  HasFactory;
    /**
     * 关联到模型的数据表
     *
     * @var string
     */
    protected $table = 'cms_member_coud';

    /**
     * The primary key associated with the table.
     *
     * @var string
     */
    protected $primaryKey = 'id';

    protected $fillable = [
        'mid',
        'min_age',
        'max_age',
        'min_age',
        'marry',
        'education',
        'job',
        'min_height',
        'max_weight',
        'salary',
        'car',
        'house',
        'child',
        'smoking',
        'drinking',
        'zodiac',
        'constellation',
        'province',
        'province_name',
        'city',
        'city_name',
        'area',
        'area_name'
    ];

    protected function serializeDate(DateTimeInterface $date)
    {
        return $date->format($this->dateFormat ?: 'Y-m-d H:i:s');
    }
}
